package com.wsl.service.impl;

import com.lww.springcloudapi.pojo.TabHallBusiness;
import com.wsl.mapper.BusinessMapper;
import com.wsl.service.BusinessService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class BusinessServiceimpl implements BusinessService {
    @Autowired
    BusinessMapper businessMapper;
    @Override
    public List<TabHallBusiness> selectbusiness() {
        return businessMapper.selectList(null);
    }

    @Override
    public int upbusiness(TabHallBusiness tabHallBusiness) {
        return businessMapper.updateById(tabHallBusiness);
    }

    @Override
    public TabHallBusiness selectbyidbusiness(Integer id) {
        return businessMapper.selectById(id);
    }

    @Override
    public int addbusiness(TabHallBusiness tabHallBusiness) {
        return businessMapper.insert(tabHallBusiness);
    }

    @Override
    public int delbyidbusiness(Integer id) {
        return businessMapper.deleteById(id);
    }

    @Override
    public int selectcount() {
        return businessMapper.selectCount(null);
    }
}
